<template>
	<view>
		<u-card :thumb="base+reactive2.avatarUrl" :title="reactive2.name">
			<view slot="body">
				<view>从业年限：{{reactive2.workStartAt}}</view>
				<view>服务人数：{{reactive2.serviceTimes}}</view>
				<view>咨询人数：{{reactive2.serviceTimes}}</view>
				<view>法律专长：{{reactive2.legalExpertiseName}}</view>
				<view>好评率：{{reactive2.favorableRate}}%</view>
			</view>
		</u-card>
		<uni-card>
			<view>受理状态:{{reactive.state == 0?'未受理':'已受理'}}</view>
			<view>问题类型:{{reactive.legalExpertiseName}}</view>
			<view>问题描述:{{reactive.content}}</view>
			<view>联系电话:{{reactive.phone}}</view>
			<image :src="base+reactive.imageUrls"></image>
			<button v-if="reactive.state == 1" @click="topin(reactive.id)">评价</button>
		</uni-card>
		
	</view>
</template>

<script>
	import api from 'commer/apiURL.js'
	export default {
		data() {
			return {
				base: api.baseurl,
				reactive: [],
				reactive2:[],
				lvshiid:'',
			}
		},
		onLoad(options) {
			this.getxian(options.id)
		},
		methods: {
			getxian(id) {
				this.$get(this.base + '/prod-api/api/lawyer-consultation/legal-advice/' + id).then((res) => {
					this.reactive = res.data
					this.$get(this.base + '/prod-api/api/lawyer-consultation/lawyer/' + res.data.lawyerId).then((res) => {
						this.reactive2 = res.data
						
					})
				})
			},
			topin(id){
				uni.navigateTo({
					url:'pingjia?id='+id
				})
			}
		}
	}
</script>

<style>

</style>
